#include <QApplication>
#include <QDialog>
#include <QPushButton>
#include <QCheckBox>
#include <QLabel>
#include <QHBoxLayout>
#include <QSpacerItem>

int main(int argc, char** argv)
{
	QApplication app(argc, argv);
	
	QDialog d(NULL);
	
	QVBoxLayout *vlay = new QVBoxLayout();
	QHBoxLayout *hlay = new QHBoxLayout();
	
	hlay->addWidget(new QLabel("Main Label"));	
	
	vlay->addWidget(new QPushButton("Hello, World!", &d));
	vlay->addItem(new QSpacerItem(50, 200, QSizePolicy::Maximum, QSizePolicy::Maximum));
	vlay->addWidget(new QCheckBox("Check me, please!", &d));
	vlay->addWidget(new QLabel("Label"));
	
	
	hlay->addItem(vlay);	
	
	d.setLayout(hlay);
	
	d.show();	
	return app.exec();
}